#pragma once

#include "../umlmodel_global.h"

#include "UMLShape.h"

namespace uml {

/// <summary>
/// UMLLabel
/// The most general class for UML shapes that are rendered only as text.
/// </summary>
class UMLMODEL_EXPORT UMLLabel : public UMLShape {

public: // Constructors and destructors
    explicit UMLLabel(const QString& umlType="uml::UMLLabel");

public: // JsonSerializable override
    void fromJson(const QJsonObject& json, QStringList& errorList) override;
    void toJson(QJsonObject& json) override;

public: // Properties
    /// <summary>
    /// text getter
    /// String to be rendered.
    /// </summary>
    QString text() const;

    /// <summary>
    /// text setter
    /// String to be rendered.
    /// </summary>
    void setText(const QString& value);

private: // Fields
    /// <summary>
    /// text
    /// String to be rendered.
    /// </summary>
    const static QString text_default_;
    QString text_= text_default_;

};

} // namespace uml
